# Contributor: Bart Ribbers <bribbers@disroot.org>

# The group tag is just to easily find this APKBUILD by some scripts for automation
# group=kde-applications
maintainer="team/kde <bribbers@disroot.org>"
pkgname=kontact
pkgver=24.08.2
pkgrel=0
# armhf blocked by extra-cmake-modules
# armv7, ppc64le, s390x, riscv64 and loongarch64 blocked by qt6-qtwebengine -> akonadi
arch="all !armv7 !armhf !ppc64le !s390x !riscv64 !loongarch64"
url="https://kontact.kde.org/"
pkgdesc="Container application to unify several major PIM applications within one application"
license="GPL-2.0-or-later"
makedepends="
	akonadi-dev
	extra-cmake-modules
	grantleetheme-dev
	kcmutils-dev
	kcrash-dev
	kdbusaddons-dev
	kdoctools-dev
	kiconthemes-dev
	kontactinterface-dev
	kpimtextedit-dev
	kwindowsystem-dev
	libkdepim-dev
	pimcommon-dev
	qt6-qtbase-dev
	qt6-qtwebengine-dev
	samurai
	"
subpackages=" $pkgname-lang"
_repo_url="https://invent.kde.org/pim/kontact.git"
source="https://download.kde.org/stable/release-service/$pkgver/src/kontact-$pkgver.tar.xz"
options="!check" # No tests

build() {
	cmake -B build -G Ninja \
		-DCMAKE_BUILD_TYPE=RelWithDebInfo \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
4c72075be15769d86ef34363705892cabd890816136ff9beb6363ac9083eeb4b14a9ccfd46d5f437d752015ca726bc5367e6131cc888a1a649b19fcde08553f1  kontact-24.08.2.tar.xz
"
